package cn.itcast.controller;


import cn.itcast.domain.Vehicle;
import cn.itcast.service.VehicleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class VehicleController {
    @Autowired
    private VehicleService vehicleService;



    @RequestMapping("/vehicle_save")
    public  String  vehicleSave(Vehicle vehicle){

        vehicleService.save(vehicle);


        return "redirect:/pages/base/vehicle.html";
    }
}
